<?php

class SelfAssesmentReportController extends Controller {

    public function actionSelfassesmentreport() {

        //get user id
        $userId = Yii::app()->getUser()->getId();
        ///contoh untuk user id 3 ... nanti di hapus
        $userId = 3;
        $userMember = User::model()->findByPk($userId);

        $assesmentId = 1;

        $data = CDataReportProvider::getSelfAssesmentReport($userMember, $assesmentId);

        $this->render('selfassesmentreport', array(
            'dataReport' => $data,
                )
        );
    }

    // Uncomment the following methods and override them if needed
    /*
      public function filters()
      {
      // return the filter configuration for this controller, e.g.:
      return array(
      'inlineFilterName',
      array(
      'class'=>'path.to.FilterClass',
      'propertyName'=>'propertyValue',
      ),
      );
      }

      public function actions()
      {
      // return external action classes, e.g.:
      return array(
      'action1'=>'path.to.ActionClass',
      'action2'=>array(
      'class'=>'path.to.AnotherActionClass',
      'propertyName'=>'propertyValue',
      ),
      );
      }
     */

    public function actionAssesmentReport() {

        //get user id
        $userId = Yii::app()->getUser()->getId();
        ///contoh untuk user id 3 ... nanti di hapus
        $userId = 3;
        $userMember = User::model()->findByPk($userId);

        $assessment_member_id = 1;

        $data = CDataReportProvider::getAssesmentReport($assessment_member_id);

        $this->render('selfassesmentreport', array(
            'dataReport' => $data,
                )
        );
    }

}